package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.HisHandCmdWeightMapper;
import com.ruoyi.system.domain.HisHandCmdWeight;
import com.ruoyi.system.service.IHisHandCmdWeightService;

/**
 * 称重回传Service业务层处理
 * 
 * @author ZYT
 * @date 2020-12-21
 */
@Service
public class HisHandCmdWeightServiceImpl implements IHisHandCmdWeightService 
{
    @Autowired
    private HisHandCmdWeightMapper hisHandCmdWeightMapper;

    /**
     * 查询称重回传
     * 
     * @param id 称重回传ID
     * @return 称重回传
     */
    @Override
    public HisHandCmdWeight selectHisHandCmdWeightById(Long id)
    {
        return hisHandCmdWeightMapper.selectHisHandCmdWeightById(id);
    }

    /**
     * 查询称重回传列表
     * 
     * @param hisHandCmdWeight 称重回传
     * @return 称重回传
     */
    @Override
    public List<HisHandCmdWeight> selectHisHandCmdWeightList(HisHandCmdWeight hisHandCmdWeight)
    {
        return hisHandCmdWeightMapper.selectHisHandCmdWeightList(hisHandCmdWeight);
    }

    /**
     * 新增称重回传
     * 
     * @param hisHandCmdWeight 称重回传
     * @return 结果
     */
    @Override
    public int insertHisHandCmdWeight(HisHandCmdWeight hisHandCmdWeight)
    {
        return hisHandCmdWeightMapper.insertHisHandCmdWeight(hisHandCmdWeight);
    }

    /**
     * 修改称重回传
     * 
     * @param hisHandCmdWeight 称重回传
     * @return 结果
     */
    @Override
    public int updateHisHandCmdWeight(HisHandCmdWeight hisHandCmdWeight)
    {
        hisHandCmdWeight.setUpdateTime(DateUtils.getNowDate());
        return hisHandCmdWeightMapper.updateHisHandCmdWeight(hisHandCmdWeight);
    }

    /**
     * 批量删除称重回传
     * 
     * @param ids 需要删除的称重回传ID
     * @return 结果
     */
    @Override
    public int deleteHisHandCmdWeightByIds(Long[] ids)
    {
        return hisHandCmdWeightMapper.deleteHisHandCmdWeightByIds(ids);
    }

    /**
     * 删除称重回传信息
     * 
     * @param id 称重回传ID
     * @return 结果
     */
    @Override
    public int deleteHisHandCmdWeightById(Long id)
    {
        return hisHandCmdWeightMapper.deleteHisHandCmdWeightById(id);
    }
}
